3.6.49 \(\int (e \cos (c+d x))^{3/2} (a+b \sin (c+d x))^2 \, dx\) [549]

3.6.49.1 Optimal result
3.6.49.2 Mathematica [A] (verified)
3.6.49.3 Rubi [A] (verified)
3.6.49.4 Maple [B] (verified)
3.6.49.5 Fricas [C] (verification not implemented)
3.6.49.6 Sympy [F(-1)]
3.6.49.7 Maxima [F]
3.6.49.8 Giac [F]
3.6.49.9 Mupad [F(-1)]

3.6.49.1 Optimal result

Integrand size = 25, antiderivative size = 149 \[ \int (e \cos (c+d x))^{3/2} (a+b \sin (c+d x))^2 \, dx=-\frac {18 a b (e \cos (c+d x))^{5/2}}{35 d e}+\frac {2 \left (7 a^2+2 b^2\right ) e^2 \sqrt {\cos (c+d x)} \operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right )}{21 d \sqrt {e \cos (c+d x)}}+\frac {2 \left (7 a^2+2 b^2\right ) e \sqrt {e \cos (c+d x)} \sin (c+d x)}{21 d}-\frac {2 b (e \cos (c+d x))^{5/2} (a+b \sin (c+d x))}{7 d e} \]

output
-18/35*a*b*(e*cos(d*x+c))^(5/2)/d/e-2/7*b*(e*cos(d*x+c))^(5/2)*(a+b*sin(d* 
x+c))/d/e+2/21*(7*a^2+2*b^2)*e^2*(cos(1/2*d*x+1/2*c)^2)^(1/2)/cos(1/2*d*x+ 
1/2*c)*EllipticF(sin(1/2*d*x+1/2*c),2^(1/2))*cos(d*x+c)^(1/2)/d/(e*cos(d*x 
+c))^(1/2)+2/21*(7*a^2+2*b^2)*e*sin(d*x+c)*(e*cos(d*x+c))^(1/2)/d
 
3.6.49.2 Mathematica [A] (verified)

Time = 1.04 (sec) , antiderivative size = 115, normalized size of antiderivative = 0.77 \[ \int (e \cos (c+d x))^{3/2} (a+b \sin (c+d x))^2 \, dx=\frac {(e \cos (c+d x))^{3/2} \left (20 \left (7 a^2+2 b^2\right ) \operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right )+\sqrt {\cos (c+d x)} \left (-84 a b \cos (2 (c+d x))+5 \left (28 a^2+5 b^2\right ) \sin (c+d x)-3 b (28 a+5 b \sin (3 (c+d x)))\right )\right )}{210 d \cos ^{\frac {3}{2}}(c+d x)} \]

input
Integrate[(e*Cos[c + d*x])^(3/2)*(a + b*Sin[c + d*x])^2,x]
 
output
((e*Cos[c + d*x])^(3/2)*(20*(7*a^2 + 2*b^2)*EllipticF[(c + d*x)/2, 2] + Sq 
rt[Cos[c + d*x]]*(-84*a*b*Cos[2*(c + d*x)] + 5*(28*a^2 + 5*b^2)*Sin[c + d* 
x] - 3*b*(28*a + 5*b*Sin[3*(c + d*x)]))))/(210*d*Cos[c + d*x]^(3/2))
 
3.6.49.3 Rubi [A] (verified)

Time = 0.62 (sec) , antiderivative size = 145, normalized size of antiderivative = 0.97, number of steps used = 11, number of rules used = 11, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.440, Rules used = {3042, 3171, 27, 3042, 3148, 3042, 3115, 3042, 3121, 3042, 3120}

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

\(\displaystyle \int (e \cos (c+d x))^{3/2} (a+b \sin (c+d x))^2 \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int (e \cos (c+d x))^{3/2} (a+b \sin (c+d x))^2dx\)

\(\Big \downarrow \) 3171

\(\displaystyle \frac {2}{7} \int \frac {1}{2} (e \cos (c+d x))^{3/2} \left (7 a^2+9 b \sin (c+d x) a+2 b^2\right )dx-\frac {2 b (e \cos (c+d x))^{5/2} (a+b \sin (c+d x))}{7 d e}\)

\(\Big \downarrow \) 27

\(\displaystyle \frac {1}{7} \int (e \cos (c+d x))^{3/2} \left (7 a^2+9 b \sin (c+d x) a+2 b^2\right )dx-\frac {2 b (e \cos (c+d x))^{5/2} (a+b \sin (c+d x))}{7 d e}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {1}{7} \int (e \cos (c+d x))^{3/2} \left (7 a^2+9 b \sin (c+d x) a+2 b^2\right )dx-\frac {2 b (e \cos (c+d x))^{5/2} (a+b \sin (c+d x))}{7 d e}\)

\(\Big \downarrow \) 3148

\(\displaystyle \frac {1}{7} \left (\left (7 a^2+2 b^2\right ) \int (e \cos (c+d x))^{3/2}dx-\frac {18 a b (e \cos (c+d x))^{5/2}}{5 d e}\right )-\frac {2 b (e \cos (c+d x))^{5/2} (a+b \sin (c+d x))}{7 d e}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {1}{7} \left (\left (7 a^2+2 b^2\right ) \int \left (e \sin \left (c+d x+\frac {\pi }{2}\right )\right )^{3/2}dx-\frac {18 a b (e \cos (c+d x))^{5/2}}{5 d e}\right )-\frac {2 b (e \cos (c+d x))^{5/2} (a+b \sin (c+d x))}{7 d e}\)

\(\Big \downarrow \) 3115

\(\displaystyle \frac {1}{7} \left (\left (7 a^2+2 b^2\right ) \left (\frac {1}{3} e^2 \int \frac {1}{\sqrt {e \cos (c+d x)}}dx+\frac {2 e \sin (c+d x) \sqrt {e \cos (c+d x)}}{3 d}\right )-\frac {18 a b (e \cos (c+d x))^{5/2}}{5 d e}\right )-\frac {2 b (e \cos (c+d x))^{5/2} (a+b \sin (c+d x))}{7 d e}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {1}{7} \left (\left (7 a^2+2 b^2\right ) \left (\frac {1}{3} e^2 \int \frac {1}{\sqrt {e \sin \left (c+d x+\frac {\pi }{2}\right )}}dx+\frac {2 e \sin (c+d x) \sqrt {e \cos (c+d x)}}{3 d}\right )-\frac {18 a b (e \cos (c+d x))^{5/2}}{5 d e}\right )-\frac {2 b (e \cos (c+d x))^{5/2} (a+b \sin (c+d x))}{7 d e}\)

\(\Big \downarrow \) 3121

\(\displaystyle \frac {1}{7} \left (\left (7 a^2+2 b^2\right ) \left (\frac {e^2 \sqrt {\cos (c+d x)} \int \frac {1}{\sqrt {\cos (c+d x)}}dx}{3 \sqrt {e \cos (c+d x)}}+\frac {2 e \sin (c+d x) \sqrt {e \cos (c+d x)}}{3 d}\right )-\frac {18 a b (e \cos (c+d x))^{5/2}}{5 d e}\right )-\frac {2 b (e \cos (c+d x))^{5/2} (a+b \sin (c+d x))}{7 d e}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {1}{7} \left (\left (7 a^2+2 b^2\right ) \left (\frac {e^2 \sqrt {\cos (c+d x)} \int \frac {1}{\sqrt {\sin \left (c+d x+\frac {\pi }{2}\right )}}dx}{3 \sqrt {e \cos (c+d x)}}+\frac {2 e \sin (c+d x) \sqrt {e \cos (c+d x)}}{3 d}\right )-\frac {18 a b (e \cos (c+d x))^{5/2}}{5 d e}\right )-\frac {2 b (e \cos (c+d x))^{5/2} (a+b \sin (c+d x))}{7 d e}\)

\(\Big \downarrow \) 3120

\(\displaystyle \frac {1}{7} \left (\left (7 a^2+2 b^2\right ) \left (\frac {2 e^2 \sqrt {\cos (c+d x)} \operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right )}{3 d \sqrt {e \cos (c+d x)}}+\frac {2 e \sin (c+d x) \sqrt {e \cos (c+d x)}}{3 d}\right )-\frac {18 a b (e \cos (c+d x))^{5/2}}{5 d e}\right )-\frac {2 b (e \cos (c+d x))^{5/2} (a+b \sin (c+d x))}{7 d e}\)

input
Int[(e*Cos[c + d*x])^(3/2)*(a + b*Sin[c + d*x])^2,x]
 
output
(-2*b*(e*Cos[c + d*x])^(5/2)*(a + b*Sin[c + d*x]))/(7*d*e) + ((-18*a*b*(e* 
Cos[c + d*x])^(5/2))/(5*d*e) + (7*a^2 + 2*b^2)*((2*e^2*Sqrt[Cos[c + d*x]]* 
EllipticF[(c + d*x)/2, 2])/(3*d*Sqrt[e*Cos[c + d*x]]) + (2*e*Sqrt[e*Cos[c 
+ d*x]]*Sin[c + d*x])/(3*d)))/7
 

3.6.49.3.1 Defintions of rubi rules used

rule 27
Int[(a_)*(Fx_), x_Symbol] :> Simp[a   Int[Fx, x], x] /; FreeQ[a, x] &&  !Ma 
tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
 

rule 3042
Int[u_, x_Symbol] :> Int[DeactivateTrig[u, x], x] /; FunctionOfTrigOfLinear 
Q[u, x]
 

rule 3115
Int[((b_.)*sin[(c_.) + (d_.)*(x_)])^(n_), x_Symbol] :> Simp[(-b)*Cos[c + d* 
x]*((b*Sin[c + d*x])^(n - 1)/(d*n)), x] + Simp[b^2*((n - 1)/n)   Int[(b*Sin 
[c + d*x])^(n - 2), x], x] /; FreeQ[{b, c, d}, x] && GtQ[n, 1] && IntegerQ[ 
2*n]
 

rule 3120
Int[1/Sqrt[sin[(c_.) + (d_.)*(x_)]], x_Symbol] :> Simp[(2/d)*EllipticF[(1/2 
)*(c - Pi/2 + d*x), 2], x] /; FreeQ[{c, d}, x]
 

rule 3121
Int[((b_)*sin[(c_.) + (d_.)*(x_)])^(n_), x_Symbol] :> Simp[(b*Sin[c + d*x]) 
^n/Sin[c + d*x]^n   Int[Sin[c + d*x]^n, x], x] /; FreeQ[{b, c, d}, x] && Lt 
Q[-1, n, 1] && IntegerQ[2*n]
 

rule 3148
Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x 
_)]), x_Symbol] :> Simp[(-b)*((g*Cos[e + f*x])^(p + 1)/(f*g*(p + 1))), x] + 
 Simp[a   Int[(g*Cos[e + f*x])^p, x], x] /; FreeQ[{a, b, e, f, g, p}, x] && 
 (IntegerQ[2*p] || NeQ[a^2 - b^2, 0])
 

rule 3171
Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x 
_)])^(m_), x_Symbol] :> Simp[(-b)*(g*Cos[e + f*x])^(p + 1)*((a + b*Sin[e + 
f*x])^(m - 1)/(f*g*(m + p))), x] + Simp[1/(m + p)   Int[(g*Cos[e + f*x])^p* 
(a + b*Sin[e + f*x])^(m - 2)*(b^2*(m - 1) + a^2*(m + p) + a*b*(2*m + p - 1) 
*Sin[e + f*x]), x], x] /; FreeQ[{a, b, e, f, g, p}, x] && NeQ[a^2 - b^2, 0] 
 && GtQ[m, 1] && NeQ[m + p, 0] && (IntegersQ[2*m, 2*p] || IntegerQ[m])
 
3.6.49.4 Maple [B] (verified)

Leaf count of result is larger than twice the leaf count of optimal. \(342\) vs. \(2(157)=314\).

Time = 6.97 (sec) , antiderivative size = 343, normalized size of antiderivative = 2.30

method result size
default \(\frac {2 e^{2} \left (240 \cos \left (\frac {d x}{2}+\frac {c}{2}\right ) \left (\sin ^{8}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) b^{2}-360 \cos \left (\frac {d x}{2}+\frac {c}{2}\right ) \left (\sin ^{6}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) b^{2}+336 \left (\sin ^{7}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) a b -140 \cos \left (\frac {d x}{2}+\frac {c}{2}\right ) \left (\sin ^{4}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) a^{2}+140 \cos \left (\frac {d x}{2}+\frac {c}{2}\right ) \left (\sin ^{4}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) b^{2}-504 \left (\sin ^{5}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) a b +70 \cos \left (\frac {d x}{2}+\frac {c}{2}\right ) \left (\sin ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) a^{2}-10 \cos \left (\frac {d x}{2}+\frac {c}{2}\right ) \left (\sin ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) b^{2}-35 \sqrt {\frac {1}{2}-\frac {\cos \left (d x +c \right )}{2}}\, \sqrt {2 \left (\sin ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )-1}\, F\left (\cos \left (\frac {d x}{2}+\frac {c}{2}\right ), \sqrt {2}\right ) a^{2}-10 \sqrt {\frac {1}{2}-\frac {\cos \left (d x +c \right )}{2}}\, \sqrt {2 \left (\sin ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )-1}\, F\left (\cos \left (\frac {d x}{2}+\frac {c}{2}\right ), \sqrt {2}\right ) b^{2}+252 a b \left (\sin ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )-42 \sin \left (\frac {d x}{2}+\frac {c}{2}\right ) a b \right )}{105 \sin \left (\frac {d x}{2}+\frac {c}{2}\right ) \sqrt {-2 \left (\sin ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) e +e}\, d}\) \(343\)
parts \(-\frac {2 a^{2} \sqrt {e \left (2 \left (\cos ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )-1\right ) \left (\sin ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}\, e^{2} \left (4 \left (\sin ^{4}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) \cos \left (\frac {d x}{2}+\frac {c}{2}\right )-2 \left (\sin ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) \cos \left (\frac {d x}{2}+\frac {c}{2}\right )+\sqrt {\frac {1}{2}-\frac {\cos \left (d x +c \right )}{2}}\, \sqrt {2 \left (\sin ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )-1}\, F\left (\cos \left (\frac {d x}{2}+\frac {c}{2}\right ), \sqrt {2}\right )\right )}{3 \sqrt {-e \left (2 \left (\sin ^{4}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )-\left (\sin ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )\right )}\, \sin \left (\frac {d x}{2}+\frac {c}{2}\right ) \sqrt {e \left (2 \left (\cos ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )-1\right )}\, d}+\frac {4 b^{2} \sqrt {e \left (2 \left (\cos ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )-1\right ) \left (\sin ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}\, e^{2} \left (24 \left (\cos ^{9}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )-60 \left (\cos ^{7}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+50 \left (\cos ^{5}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )-15 \left (\cos ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )-\sqrt {\frac {1}{2}-\frac {\cos \left (d x +c \right )}{2}}\, \sqrt {-2 \left (\cos ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+1}\, F\left (\cos \left (\frac {d x}{2}+\frac {c}{2}\right ), \sqrt {2}\right )+\cos \left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{21 \sqrt {-e \left (2 \left (\sin ^{4}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )-\left (\sin ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )\right )}\, \sin \left (\frac {d x}{2}+\frac {c}{2}\right ) \sqrt {e \left (2 \left (\cos ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )-1\right )}\, d}-\frac {4 a b \left (e \cos \left (d x +c \right )\right )^{\frac {5}{2}}}{5 d e}\) \(424\)

input
int((e*cos(d*x+c))^(3/2)*(a+b*sin(d*x+c))^2,x,method=_RETURNVERBOSE)
 
output
2/105/sin(1/2*d*x+1/2*c)/(-2*sin(1/2*d*x+1/2*c)^2*e+e)^(1/2)*e^2*(240*cos( 
1/2*d*x+1/2*c)*sin(1/2*d*x+1/2*c)^8*b^2-360*cos(1/2*d*x+1/2*c)*sin(1/2*d*x 
+1/2*c)^6*b^2+336*sin(1/2*d*x+1/2*c)^7*a*b-140*cos(1/2*d*x+1/2*c)*sin(1/2* 
d*x+1/2*c)^4*a^2+140*cos(1/2*d*x+1/2*c)*sin(1/2*d*x+1/2*c)^4*b^2-504*sin(1 
/2*d*x+1/2*c)^5*a*b+70*cos(1/2*d*x+1/2*c)*sin(1/2*d*x+1/2*c)^2*a^2-10*cos( 
1/2*d*x+1/2*c)*sin(1/2*d*x+1/2*c)^2*b^2-35*(sin(1/2*d*x+1/2*c)^2)^(1/2)*(2 
*sin(1/2*d*x+1/2*c)^2-1)^(1/2)*EllipticF(cos(1/2*d*x+1/2*c),2^(1/2))*a^2-1 
0*(sin(1/2*d*x+1/2*c)^2)^(1/2)*(2*sin(1/2*d*x+1/2*c)^2-1)^(1/2)*EllipticF( 
cos(1/2*d*x+1/2*c),2^(1/2))*b^2+252*a*b*sin(1/2*d*x+1/2*c)^3-42*sin(1/2*d* 
x+1/2*c)*a*b)/d
 
3.6.49.5 Fricas [C] (verification not implemented)

Result contains higher order function than in optimal. Order 9 vs. order 4.

Time = 0.11 (sec) , antiderivative size = 143, normalized size of antiderivative = 0.96 \[ \int (e \cos (c+d x))^{3/2} (a+b \sin (c+d x))^2 \, dx=\frac {-5 i \, \sqrt {2} {\left (7 \, a^{2} + 2 \, b^{2}\right )} e^{\frac {3}{2}} {\rm weierstrassPInverse}\left (-4, 0, \cos \left (d x + c\right ) + i \, \sin \left (d x + c\right )\right ) + 5 i \, \sqrt {2} {\left (7 \, a^{2} + 2 \, b^{2}\right )} e^{\frac {3}{2}} {\rm weierstrassPInverse}\left (-4, 0, \cos \left (d x + c\right ) - i \, \sin \left (d x + c\right )\right ) - 2 \, {\left (42 \, a b e \cos \left (d x + c\right )^{2} + 5 \, {\left (3 \, b^{2} e \cos \left (d x + c\right )^{2} - {\left (7 \, a^{2} + 2 \, b^{2}\right )} e\right )} \sin \left (d x + c\right )\right )} \sqrt {e \cos \left (d x + c\right )}}{105 \, d} \]

input
integrate((e*cos(d*x+c))^(3/2)*(a+b*sin(d*x+c))^2,x, algorithm="fricas")
 
output
1/105*(-5*I*sqrt(2)*(7*a^2 + 2*b^2)*e^(3/2)*weierstrassPInverse(-4, 0, cos 
(d*x + c) + I*sin(d*x + c)) + 5*I*sqrt(2)*(7*a^2 + 2*b^2)*e^(3/2)*weierstr 
assPInverse(-4, 0, cos(d*x + c) - I*sin(d*x + c)) - 2*(42*a*b*e*cos(d*x + 
c)^2 + 5*(3*b^2*e*cos(d*x + c)^2 - (7*a^2 + 2*b^2)*e)*sin(d*x + c))*sqrt(e 
*cos(d*x + c)))/d
 
3.6.49.6 Sympy [F(-1)]

Timed out. \[ \int (e \cos (c+d x))^{3/2} (a+b \sin (c+d x))^2 \, dx=\text {Timed out} \]

input
integrate((e*cos(d*x+c))**(3/2)*(a+b*sin(d*x+c))**2,x)
 
output
Timed out
 
3.6.49.7 Maxima [F]

\[ \int (e \cos (c+d x))^{3/2} (a+b \sin (c+d x))^2 \, dx=\int { \left (e \cos \left (d x + c\right )\right )^{\frac {3}{2}} {\left (b \sin \left (d x + c\right ) + a\right )}^{2} \,d x } \]

input
integrate((e*cos(d*x+c))^(3/2)*(a+b*sin(d*x+c))^2,x, algorithm="maxima")
 
output
integrate((e*cos(d*x + c))^(3/2)*(b*sin(d*x + c) + a)^2, x)
 
3.6.49.8 Giac [F]

\[ \int (e \cos (c+d x))^{3/2} (a+b \sin (c+d x))^2 \, dx=\int { \left (e \cos \left (d x + c\right )\right )^{\frac {3}{2}} {\left (b \sin \left (d x + c\right ) + a\right )}^{2} \,d x } \]

input
integrate((e*cos(d*x+c))^(3/2)*(a+b*sin(d*x+c))^2,x, algorithm="giac")
 
output
integrate((e*cos(d*x + c))^(3/2)*(b*sin(d*x + c) + a)^2, x)
 
3.6.49.9 Mupad [F(-1)]

Timed out. \[ \int (e \cos (c+d x))^{3/2} (a+b \sin (c+d x))^2 \, dx=\int {\left (e\,\cos \left (c+d\,x\right )\right )}^{3/2}\,{\left (a+b\,\sin \left (c+d\,x\right )\right )}^2 \,d x \]

input
int((e*cos(c + d*x))^(3/2)*(a + b*sin(c + d*x))^2,x)
 
output
int((e*cos(c + d*x))^(3/2)*(a + b*sin(c + d*x))^2, x)